const propsMap = new Map([
  /* 共用 */
  ['orderType', {label: '订单类型', prop: 'orderType', width: 120, slots: {default: 'orderType'}}],
  ['cardImg', {label: '卡牌图片', prop: 'cardImg', width: 90, slots: {default: 'cardImg'}}],
  ['cardId', {label: '卡牌UID', prop: 'cardId', width: 190}],
  ['userWmsId', {label: '私人仓货架ID', prop: 'userWmsId', width: 140}],
  ['checked', {label: '操作', prop: 'checked', width: 70, slots: {default: 'checked'}, fixed: 'right'}],
  ['rating_viewer',  {label: '评级类型', prop: 'rating', width: 90}],
  ['ratingNo_editor', {label: '评级号码', prop: 'ratingNo_editor', width: 180, slots: {default: 'ratingNo_editor'}}],
  ['wmsStatus_order', {label: '入库状态', prop: 'wmsStatus_order', slots: {default: 'wmsStatus_order'}}],

  /* 入库订单列表 */
  ['trackingNo_in', {label: '签收物流单号', prop: 'trackingNo', width: 200}],
  ['logisticsCompany', {label: '签收物流公司', prop: 'logisticsCompany', width: 140}],
  ['orderNo_in', {label: '送卡订单UID', prop: 'orderNo'}],
  ['sendOutTime', {label: '确认寄出时间', prop: 'sendOutTime', width: 180}],
  ['reviewTime', {label: '初审时间', prop: 'reviewTime', width: 160}],
  ['reviewTime', {label: '复核时间', prop: 'reviewTime', width: 180}],
  ['sendCount', {label: '送卡数量', prop: 'sendCount', width: 90}],
  ['instockTime', {label: '入库时间', prop: 'instockTime', width: 180}],
  ['matchResult', {label: '匹配结果', prop: 'matchResult', width: 120, slots: {default: 'matchResult'}}],
  ['logisticsStatus', {label: '物流状态', prop: 'logisticsStatus', width: 140}],
  ['signTime', {label: '签收时间', prop: 'signTime', width: 180}],
  ['signPerson', {label: '签收人', prop: 'signPerson', width: 120}],
  ['checked_hidden', {label: '操作', prop: 'checked', width: 70, hidden: true, slots: {default: 'checked'}, fixed: 'right'}],
  /* 卡牌列表 */
  ['orderNo-card', {label: '销售订单UID', prop: 'orderNo'}], //
  ['cardName',  {label: '卡牌名称', prop: 'cardName'}],
  ['rating_editor',  {label: '评级类型', prop: 'rating_editor', width: 140, slots: {default: 'rating_editor'}}],
  ['score_viewer', {label: '分数', prop: 'score', width: 140}],
  ['score_editor', {label: '分数', prop: 'score_editor', width: 140, slots: {default: 'score_editor'}}],
  ['ratingNo_viewer', {label: '评级号码', prop: 'ratingNo', width: 160}],
  ['stockStatus', {label: '状态', prop: 'stockStatus', width: 120, slots: {default: 'stockStatus'}}],
  ['originScan', {label: '原卡扫描', prop: 'originScan', width: 210, slots: {default: 'originScan'}}],
  ['stickerPhotoUrl', {label: '卡牌贴标扫描', prop: 'stickerPhotoUrl', width: 140, slots: {default: 'stickerPhotoUrl'}}],
  ['firstReview', {label: '卡牌初审', prop: 'firstReview', width: 300, fixed: 'right', slots: {default: 'firstReview'}}],
  ['firstReviewResult', {label: '初审结果', prop: 'firstReviewResult', width: 300, slots: {default: 'firstReviewResult'}}],
  ['reviewResult', {label: '复核结果', prop: 'reviewResult', width: 120, slots: {default: 'reviewResult'}}],
  ['wmsStatus_card', {label: '入库状态', prop: 'wmsStatus_card', width: 120, slots: {default: 'wmsStatus_card'}}], //
  ['cardStatus_card', {label: '入库状态', prop: 'cardStatus_card', width: 120, slots: {default: 'cardStatus_card'}}],
  ['cardId_editor', {label: '卡牌UID', prop: 'cardId_editor', width: 240, slots: {default: 'cardId_editor'}}],
  ['cardStatus_return', {label: '状态', prop: 'cardStatus_card', width: 120, slots: {default: 'cardStatus_card'}}],
  ['delete', {label: '操作', prop: 'delete', width: 90, slots: {default: 'delete'}, fixed: 'right'}],
  /* 出库订单列表 */
  ['pickUid', {label: '拣货单UID', prop: 'pickUid', width: 120}],
  ['picker', {label: '拣货人', prop: 'picker', width: 120}],
  ['pickTime', {label: '拣货时间', prop: 'pickTime', width: 180}],
  ['orderOutNo', {label: '销售订单UID', prop: 'orderOutNo', width: 120}],
  ['name_out', {label: '标题', prop: 'name'}],
  ['sendType', {label: '售卖模式', prop: 'sendType', width: 90, slots: {default: 'sendType'}}],
  ['cardsId', {label: '合集ID', prop: 'cardsId', width: 80}],
  ['userNickname', {label: '卖家', prop: 'userNickname', width: 120}],
  ['createTime', {label: '创建时间', prop: 'createTime', width: 180}],
  ['cardStatus-order', {label: '订单状态', prop: 'cardStatus-order', width: 120, slots: {default: 'cardStatus-order'}}],
  ['sendTime', {label: '发货时间', prop: 'sendTime', width: 180}],
  ['logisticsCompany', {label: '发货物流公司', prop: 'logisticsCompany', width: 140}],
  ['trackingNo_out', {label: '发货物流单号', prop: 'trackingNo', width: 140}], //
  ['cardStatus_out', {label: '订单状态', prop: 'cardStatus_out', width: 120, slots: {default: 'cardStatus_out'}}],
  ['sendName', {label: '发货人', prop: 'sendName', width: 120}],
  ['viewerDetail', {label: '操作', prop: 'viewerDetail', width: 90, slots: {default: 'viewerDetail'}, fixed: 'right'}],
  /* 云仓 */
  ['name_clouds', {label: '用户昵称', prop: 'name'}],
  ['userUID', {label: '用户UID', prop: 'userUID'}],
  ['cardTime', {label: '卡牌入库时间', prop: 'cardTime', width: 140}]
])

// 获取根据prop列配置
const getColumns = (props) => props.map(prop => propsMap.get(prop))

const columnsMap = new Map([
  /* 出库订单列表*/
  // 快递签收
  [1, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'sendOutTime', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson'])],
  // 开箱初审
  [2, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'sendOutTime', 'matchResult', 'logisticsStatus', 'sendOutTime', 'signPerson', 'wmsStatus_order'])],
  // 开箱初审
  [3, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'reviewTime', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson', 'wmsStatus_order'])],
  // 待入库订单
  [4, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'reviewTime', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson', 'wmsStatus_order'])],
  // 待入库订单
  [5, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'instockTime', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson', 'wmsStatus_order'])],
  // 退货入库
  [6, getColumns(['trackingNo_in', 'logisticsCompany', 'orderType', 'sendCount', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson', 'wmsStatus_order'])],
  // 全部已入库订单
  [7, getColumns(['trackingNo_in', 'logisticsCompany', 'orderNo_in', 'orderType', 'sendCount', 'instockTime', 'matchResult', 'logisticsStatus', 'signTime', 'signPerson', 'wmsStatus_order'])],

  /* 卡牌列表 */
  // 初审详情卡牌列表
  [9, getColumns(['cardImg', 'cardId', 'cardName', 'rating_editor', 'score_editor', 'ratingNo_editor', 'stockStatus', 'originScan', 'stickerPhotoUrl', 'firstReview'])],
  // 待复核详情卡牌列表
  [10, getColumns(['cardImg', 'cardId', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'stockStatus', 'originScan', 'stickerPhotoUrl', 'firstReviewResult'])],
  // 待入库详情卡牌列表
  [11, getColumns(['cardImg', 'cardId', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'stockStatus', 'originScan', 'stickerPhotoUrl', 'reviewResult', 'userWmsId', 'cardStatus_card', 'checked'])],
  // 待回寄卡牌订单详情卡牌列表
  [12, getColumns(['cardImg', 'cardId', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'stockStatus', 'originScan', 'stickerPhotoUrl', 'reviewResult', 'userWmsId', 'cardStatus_card', 'checked'])],
  // 已入库订单详情卡牌列表
  [13, getColumns(['cardImg', 'cardId', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'stockStatus', 'originScan', 'stickerPhotoUrl', 'reviewResult', 'userWmsId', 'cardStatus_card'])],
  // 退货入库详情填写
  [20, getColumns(['cardId_editor', 'cardImg', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_editor', 'cardStatus_return', 'userWmsId', 'delete'])],
  // 退货入库详情确定
  [21, getColumns(['cardId', 'cardImg', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'cardStatus_return', 'userWmsId', 'wmsStatus_order', 'checked'])],


  /* 出库订单列表 */
  // 待拣货列表
  [14, getColumns(['cardImg', 'orderOutNo', 'orderType', 'cardId', 'name', 'rating_viewer', 'sendType', 'cardsId', 'userNickname', 'userWmsId', 'createTime', 'cardStatus_out', 'checked'])],
  // 待确认出仓
  [15, getColumns(['pickUid', 'picker', 'pickTime', 'cardImg', 'orderOutNo', 'orderType', 'cardId', 'name_out', 'rating_viewer', 'sendType', 'cardsId', 'userNickname', 'userWmsId', 'createTime', 'cardStatus_out', 'checked'])],
  // 待发货
  [16, getColumns(['pickUid', 'picker', 'pickTime', 'cardImg', 'orderOutNo', 'orderType', 'cardId', 'name_out', 'rating_viewer', 'sendType', 'cardsId', 'userNickname', 'userWmsId', 'createTime', 'cardStatus_out', 'checked'])],
  // 已发货
  [17, getColumns(['cardImg', 'orderOutNo', 'orderType', 'cardId', 'name_out', 'rating_viewer', 'sendType', 'cardsId', 'userNickname', 'userWmsId', 'createTime', 'cardStatus_out', 'sendTime', 'logisticsCompany', 'trackingNo_out', 'sendName', 'viewerDetail'])],
  // 已发货详情卡牌列表
  [18, getColumns(['cardImg', 'orderOutNo', 'orderType', 'cardId', 'name_out', 'rating_viewer', 'sendType', 'cardsId', 'userNickname', 'userWmsId', 'createTime', 'cardStatus_out'])],

  /* 云仓 */
  // 云仓列表
  [19, getColumns(['name_clouds', 'userUID', 'cardImg', 'cardId', 'cardName', 'rating_viewer', 'score_viewer', 'ratingNo_viewer', 'orderType', 'userWmsId', 'cardTime'])]

  // 22
])

export default columnsMap
